package cn.hdc.os.dao;

import cn.hdc.os.entity.Department;
import cn.hdc.os.entity.Employee;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository("employeeDao")
//用户持久层
public interface EmployeeDao {
    //新增用户
    void insert(Employee employee);

    //修改用户
    void update(Employee employee);

    //删除用户
    void delete(String sn);

    //根据sn查找用户
    Employee select(String sn);

    //查找所有用户
    List<Employee> selectAll();

    //根据部门和职位查找用户
    List<Employee> selectByDepartmentAndPost(@Param("dsn") String dsn, @Param("post") String post);
}
